package com.sunwayhorizo.health.hl7.persistent.pk;

import java.io.Serializable;

public class RimCoreRoleCdSetsPK implements Serializable {
    public Long roleCodeSetId;
    public Long roleId;
    public Long roleVersionNum;

    public RimCoreRoleCdSetsPK() {
    }

    public RimCoreRoleCdSetsPK(Long roleCodeSetId, Long roleId, 
                               Long roleVersionNum) {
        this.roleCodeSetId = roleCodeSetId;
        this.roleId = roleId;
        this.roleVersionNum = roleVersionNum;
    }

    public boolean equals(Object other) {
        if (other instanceof RimCoreRoleCdSetsPK) {
            final RimCoreRoleCdSetsPK otherRimCoreRoleCdSetsPK = (RimCoreRoleCdSetsPK) other;
            final boolean areEqual = 
                (otherRimCoreRoleCdSetsPK.roleCodeSetId.equals(roleCodeSetId) && otherRimCoreRoleCdSetsPK.roleId.equals(roleId) && otherRimCoreRoleCdSetsPK.roleVersionNum.equals(roleVersionNum));
            return areEqual;
        }
        return false;
    }

    public int hashCode() {
        return super.hashCode();
    }
}
